package com.summer.common.activiti.service;

import org.activiti.api.runtime.shared.identity.UserGroupManager;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

@Component
public class CustomUserGroupManagerImpl implements UserGroupManager {

    public static List<String> groups;



    @Override
    public List<String> getUserGroups(String username) {
        if (groups == null){
            groups = new ArrayList<>();
            groups.add("allUser");
        }
        return groups;
    }

    @Override
    public List<String> getUserRoles(String username) {
        return null;
    }

    @Override
    public List<String> getGroups() {
        return null;
    }

    @Override
    public List<String> getUsers() {
        return null;
    }
}
